package com.nuc.iblog.jpa.cl;

import com.nuc.iblog.entity.Picture;
import com.nuc.iblog.entity.User;
import com.nuc.iblog.jpa.BaseJpa;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.repository.NoRepositoryBean;

import java.util.List;

@NoRepositoryBean
public interface ClPictureJpa extends BaseJpa<Picture,Integer> {
    List<Picture> findAllByUser(User user);
    Page<Picture> findAllByUserOrderByPidDesc(User user, Pageable pageable);
}
